package b3.widget.home.top
{
	import b3.model.*;
	import b3.net.*;
	import b3.scene.home.*;
	import b3.widget.*;
	import b3.widget.basic.*;
	import b3.widget.match.*;
	import b3.widget.store.*;
	import b3.widget.guinness.*;
	
	import flash.events.MouseEvent;
	
	public class GuinnessIcon extends BasicIcon
	{
		public function GuinnessIcon()
		{
			var IconBgr:Class = ResourceHelper.getInstance().getClassByName("GuinnessIcon");
			super(IconBgr, "吉尼斯", 1, true);
			addEventListener(MouseEvent.CLICK, onMouseClick);
		}
		
		private function onMouseClick(event:MouseEvent):void
		{
			if (HomeScene.getInstance().getOperationMode() == HomeScene.NONEMODE)
			{
				var guinnessDialog:GuinnessDialog = GuinnessDialog.getInstance();
				guinnessDialog.x = -guinnessDialog.width / 2;
				guinnessDialog.y = -guinnessDialog.height / 2;
				WidgetManager.getInstance().popOut([guinnessDialog], true);
			}
		}
	}
}